<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<ui:composition xmlns:ui="http://java.sun.com/jsf/facelets"
                template="./../template/template.xhtml"
                xmlns:h="http://java.sun.com/jsf/html"
                xmlns:f="http://java.sun.com/jsf/core">

    <ui:define name="title">
        #{bundle.Register}
    </ui:define>

    <ui:define name="content">
        <h:panelGroup id="messagePanel" layout="block">
                <h:messages errorStyle="color: red" infoStyle="color: green" layout="table"/>
            </h:panelGroup>
            <h:form>
                <h:panelGrid columns="2">
                    <h:outputLabel value="#{bundle.CreateuserLabel_firstName}" for="firstName" />
                    <h:inputText id="firstName" value="#{userController.selected.firstName}" title="#{bundle.CreateuserTitle_firstName}" />
                    <h:outputLabel value="#{bundle.CreateuserLabel_lastName}" for="lastName" />
                    <h:inputText id="lastName" value="#{userController.selected.lastName}" title="#{bundle.CreateuserTitle_lastName}" />
                    <h:outputLabel value="#{bundle.CreateuserLabel_login}" for="login" />
                    <h:inputText id="login" value="#{userController.selected.login}" title="#{bundle.CreateuserTitle_login}" required="true"/>
                    <h:outputLabel value="#{bundle.CreateuserLabel_password}" for="password" />
                    <h:inputSecret id="password" value="#{userController.selected.password}" title="#{bundle.CreateuserTitle_password}" required="true"/>
                </h:panelGrid>
                <h:commandLink action="#{userController.register}" value="#{bundle.CreateuserSaveLink}" />
            </h:form>
    </ui:define>

</ui:composition>
